// 导入需要的config和request
import confing from '../config/config.js';
import request from '../util/request.js';
// 申明请求对象
const holidayRequest = {
  // dict请求的基本url
  BASE_URL: confing.CAL_URL + "/holiday",

  //添加节假日数据
  save(calHoliday,callback){
    let url = this.BASE_URL + "/save";
    request.post(url,calHoliday,callback);
  },
  // 分页查询
  list(callbcak) {
    // url
    let url = this.BASE_URL + "/list";
    // 发送请求
    request.get(url, callbcak);
  }
}
// 将dictRequest暴漏出去
export default holidayRequest;